﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using BuildPlannerLib.PlayerActions;

namespace BuildPlannerLib.SimEvents
{
    // Derived class from Event for finishing an action
    public class FinishAction : SimEvent
    {
        // Field for the action to be finished
        public PlayerAction Action;

        // Constructor with parameters for action and time
        public FinishAction(PlayerAction action, int time)
        {
            Action = action;
            Time = time;
        }

        // Finishes the action
        public override void Execute()
        {
            Action.FinishAction();
        }
    }
}
